.box-shadow (@x: 0, @y: 0, @blur: 1px, @color: #000) {
  box-shadow: @arguments;
  -moz-box-shadow: @arguments;
  -webkit-box-shadow: @arguments;
}
.select-none(@argu:none) {
  -moz-user-select: @argu;
  -o-user-select:@argu;
  -webkit-user-select:@argu;
  -ms-user-select:@argu;
  user-select:@argu;
}
.border-radius (@radius: 0px) {
  -moz-border-radius: @radius;
  -ms-border-radius:@radius;
  -webkit-border-radius: @radius;
  border-radius: @radius;

}
.scale(@x, @y) {
  -webkit-transform:scale(@x, @y);
  -ms-transform: scale(@x, @y);
  -moz-transform: scale(@x, @y);
  transform: scale(@x, @y);
}
.translate3d (@x:0, @y:0, @z:0) {
  -webkit-transform:translate3d(@x, @y, @z);
  -ms-transform: translate3d(@x, @y, @z);
  -moz-transform: translate3d(@x, @y, @z);
  transform: translate3d(@x, @y, @z);
}
.transition(@time:.3s,@attr:all,@fun:ease-in) {
  -webkit-transition: @time @attr @fun;
  -moz-transition:@time @attr @fun ;
  -ms-transition:@time @attr @fun;
  transition:@time @attr @fun;
}
.rotate(@deg:0) {
  -webkit-transform:rotate(@deg);
  -ms-transform: rotate(@deg);
  -moz-transform: rotate(@deg);
  transform: rotate(@deg);
}


//清除浮动
.clearfix() {
  *zoom: 1;
&:before, &:after{display:table;content:""}
&:after{clear:both}
}

// 省略
.ellipsis() {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.box-ellipsis(){
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    white-space: initial;
    overflow: hidden;
}
.gradient(@origin: top, @startColor, @endColor){
  background-color:@startColor/2 + @endColor/2;
  background-image: -webkit-linear-gradient(@origin, @startColor, @endColor);
  background-image:-moz-linear-gradient(@origin, @startColor, @endColor);
  background-image: -o-linear-gradient(@origin, @startColor, @endColor);
  background-image: -ms-linear-gradient(@origin, @startColor, @endColor);
  background-image: linear-gradient(@origin, @startColor, @endColor);
}
.inner-shadow(@param1,@param2,@param3,@opacity){
    -webkit-box-shadow:inset @param1 @param2 @param3 rgba(0, 0, 0, @opacity);
    -moz-box-shadow:inset @param1 @param2 @param3 rgba(0, 0, 0, @opacity);
    box-shadow:inset @param1 @param2 @param3 rgba(0, 0, 0, @opacity);
}


// 文字自动换行
.break-word() {
  word-wrap: break-word;
  word-break: break-all;
}

// 伸缩盒
.flex-init() {
  display: -webkit-box;
  display: -webkit-flex;
  display: -moz-box;
  display: -moz-flex;
  display: -ms-flexbox;
  display: flex;
}
.flex-layout(@align:center) {
  display: -webkit-box;
  display: -webkit-flex;
  display: -moz-box;
  display: -moz-flex;
  display: -ms-flexbox;
  display: flex;
  -moz-box-align:@align;
  -webkit-box-align:@align;
  -webkit-box-align: @align;
  -moz-box-align: @align;
  -ms-flex-align:@align;
  -webkit-justify-content: @align;
  -moz-justify-content: @align;
  justify-content: @align;

}
.inline-flex-layout(@align:center) {
  display: -webkit-inline-box;
  display: -moz-inline-box;
  display: -webkit-inline-flex;
  display: -moz-inline-flex;
  display: -ms-flexbox;
  display: inline-flex;
  -moz-box-align:@align;
  -webkit-box-align:@align;
  -webkit-box-align: @align;
  -moz-box-align: @align;
  -ms-flex-align:@align;
  -webkit-justify-content: @align;
  -moz-justify-content: @align;
  justify-content: @align;
}
.flex-vertical() {
  -webkit-box-pack: center;
  -moz-box-pack: center;
  -ms-flex-pack:center;
  -webkit-align-items: center;
  -moz-align-items: center;
  align-items: center;
}
.flex-vertical-column {
  -webkit-box-orient:vertical;
  -moz-box-orient:vertical;
  box-orient:vertical;
  -webkit-box-direction: normal;
  -moz-box-direction: normal;
  box-direction:normal;
  -webkit-flex-direction: column;
  -ms-flex-direction: column;
  -moz-box-direction: column;
  flex-direction: column;
}
//子元素设置
.flex(@n) {
  display: block;
  -webkit-box-flex: @n;
  -moz-box-flex: @n;
  box-flex: @n;
  flex:@n;
}

.noflex() {
  -webkit-box-flex: 0 !important;
}
.bottom_line(){
  &::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;

    background: #ddd;
  }
}
.head_bottom_line(){
  &::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;

    background: #ddd;
  }
}
